package com.chalk.util;

public class ImgUtil {

    public  static final String [] SUFFIXS={"jpg","png","gif","JPG","PNG","GIF"};

    public static Boolean checkImg(String suffix){
        Boolean f=false;
        for(String s:SUFFIXS){
            if(s.equals(suffix)){
             f=true;
             break;
            }
        }

        return f;

    }

    public static String splitImg(String imgName){
        String[] arr=imgName.split("\\.");
        return arr[arr.length-1];
    }

}
